package com.bw.product.controller;

import com.bw.common.core.domain.Result;
import com.bw.common.core.utils.poi.ExcelUtil;
import com.bw.common.core.web.controller.BaseController;

import com.bw.common.security.annotation.RequiresPermissions;
import com.bw.product.domain.PmsSpuInfoDesc;
import com.bw.product.service.PmsSpuInfoDescService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;

import javax.servlet.http.HttpServletResponse;
import java.util.List;

/**
 * spu信息介绍Controller
 */
@RestController
@RequestMapping("/PmsSpuInfoDesc")
public class PmsSpuInfoDescController extends BaseController
{
    @Autowired
    private PmsSpuInfoDescService pmsSpuInfoDescService;



    /**
     * 根据spuId获取spu信息介绍详细信息
     */
    @RequiresPermissions("product:PmsSpuInfoDesc:query")
    @GetMapping(value = "/{spuId}")
    public Result<PmsSpuInfoDesc> getInfo(@PathVariable("spuId") Long spuId)
    {
        PmsSpuInfoDesc pmsSpuInfoDesc=pmsSpuInfoDescService.selectPmsSpuInfoDescBySpuId(spuId);
        return Result.success(pmsSpuInfoDesc);
    }


}
